{% extends 'template.html' %}

{% block username %}
    {{ head.username }}
{% endblock %}

{% block content %}
    <div id="page-wrapper">
        <div class="row">
            <div class="col-lg-12">
                <h1 class="page-header">{{ head.value }}</h1>
                <h1 class="page-header" id="workflow_id" style="display: none;">{{ head.workflow }}</h1>
                <h1 class="page-header" id="first_name" style="display: none;">{{ first_name }}</h1>
                <input class="hidden" id="new_edition" value="{{ new_edition }}">
            </div>
        </div>
        <div class="row">
            <div class="col-lg-12">
                <div class="panel panel-default">
                    <div class="panel-body">
                        <div class="row">
                            <div class="col-lg-6">
                                <div class="container">
                                    <form role="form" class="form-horizontal">
                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">申请人</label>
                                            <div class="col-sm-6">
                                                <input class="form-control" id="applicant"
                                                       value={{ applicant }} readonly="readonly"></input>
                                            </div>
                                        </div>
                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">标题</label>
                                            <div class="col-sm-6">
                                                <input class="form-control" id="title"></input>
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">更新内容</label>
                                            <div class="col-sm-6">
                                                <textarea class="form-control" id="content" rows="10"></textarea>
                                            </div>
                                        </div>

                                        <div class="form-group" id="add_server_list_after">
                                            <label class="col-sm-12" for="TextArea">项目</label>
                                            <div class="col-sm-6">
                                                <select id="project" style="width: 100%">
                                                    <option value="0" selected="selected">选择项目</option>
                                                </select>
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">区服列表</label>
                                            <div class="col-sm-6">
                                                <textarea class="form-control" id="server_list" rows="10"></textarea>
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">起止时间(以北京时间为准)</label>
                                            <div class="col-sm-2">
                                                <input class="flatpickr flatpickr-input" type="text"
                                                       placeholder="选择开始时间" data-id="datetime" id="start_time"
                                                       readonly="readonly">
                                            </div>
                                            <div class="col-sm-2">
                                                <input class="flatpickr flatpickr-input" type="text"
                                                       placeholder="选择结束时间" data-id="datetime" id="end_time"
                                                       readonly="readonly">
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">后端负责人</label>
                                            <div class="col-sm-6">
                                                <select id="server_charge" style="width: 100%">
                                                    <option value="0" selected="selected">选择后端负责人</option>
                                                </select>
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">前端负责人</label>
                                            <div class="col-sm-6">
                                                <select id="client_charge" style="width: 100%">
                                                    <option value="0" selected="selected">选择前端负责人</option>
                                                </select>
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">策划负责人</label>
                                            <div class="col-sm-6">
                                                <select id="plan_charge" style="width: 100%">
                                                    <option value="0" selected="selected">选择策划负责人</option>
                                                </select>
                                            </div>
                                        </div>

                                        <div class="form-group">
                                            <label class="col-sm-12" for="TextArea">测试负责人</label>
                                            <div class="col-sm-6">
                                                <select id="test_charge" style="width: 100%">
                                                    <option value="0" selected="selected">选择测试负责人</option>
                                                </select>
                                            </div>
                                        </div>


                                        <div class="form-group">
                                            <label class="col-sm-12">流程步骤</label>
                                            <div class="col-sm-6">
                                                <p>{{ state_step.value }}</p>
                                            </div>
                                        </div>
                                        <div class="form-group" id='append_before'>
                                            <div class="col-sm-6">
                                                <button type="button" class="btn btn-primary" id='bt-commit'>提交</button>
                                            </div>
                                        </div>
                                    </form>
                                    <hr>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
{% endblock %}
{% block bodyjs %}
    <script src="/static/js/flatpickr.js"></script>
    <script src="/static/js/zh.js"></script>
    <script src="/static/js/version_update_workflow.js?v=20190906001"></script>
    <script src="/static/js/jquery.tree-multiselect.js"></script>
{% endblock %}
{% block css %}
    <link href="/static/css/flatpickr.css" rel="stylesheet" type="text/css">
    <link href="/static/css/flatpickr_material_green.css" rel="stylesheet" type="text/css">
    <link href="/static/css/jquery.tree-multiselect.css" rel="stylesheet" type="text/css">
{% endblock %}
